package com.onpositive.data.kvstorage;

import java.io.Serializable;
import java.util.HashSet;

import com.onpositive.semantic.model.api.property.java.annotations.Caption;
import com.onpositive.semantic.model.api.property.java.annotations.Id;
import com.onpositive.semantic.model.api.property.java.annotations.ReadOnly;


public class DataCollectionInfo implements Serializable{

	/**
	 * s
	 */
	private static final long serialVersionUID = 1L;

	@Id
	@ReadOnly("^$value")
	@Caption("Name")
	protected String name;

	@Override
	public int hashCode() {
		final int prime = 31;
		int result = 1;
		result = prime * result + ((name == null) ? 0 : name.hashCode());
		return result;
	}

	@Override
	public boolean equals(Object obj) {
		if (this == obj)
			return true;
		if (obj == null)
			return false;
		if (getClass() != obj.getClass())
			return false;
		DataCollectionInfo other = (DataCollectionInfo) obj;
		if (name == null) {
			if (other.name != null)
				return false;
		} else if (!name.equals(other.name))
			return false;
		return true;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public HashSet<String> getSuperCollections() {
		return superCollections;
	}

	public void setSuperCollections(HashSet<String> superCollections) {
		this.superCollections = superCollections;
	}

	public String getDomain() {
		return domain;
	}

	public void setDomain(String domain) {
		this.domain = domain;
	}

	public String getDescription() {
		return description;
	}

	public void setDescription(String description) {
		this.description = description;
	}

	protected HashSet<String> childrenCollections;
	protected HashSet<String> superCollections;

	protected String domain;

	protected String description;
	
	@Override
	public String toString() {
		return name;
	}
}
